﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;
using Microsoft.Practices.Unity;
using Triunfadores.BusinessEntities;
using Triunfadores.BusinessLogic.Service;

namespace Triunfadores.Api.Controllers
{
    public class SolicitudesPrestamosController : ApiController
    {
        #region Declaracion de Dependencias
        [Dependency]
        public ISolicitudPrestamoService SolicitudPrestamoService { get; set; }
        #endregion

        // GET api/<controller>
        //public IEnumerable<string> Get()
        //{
        //    return new string[] { "value1", "value2" };
        //}
        public IEnumerable<SolicitudPrestamo> Get()
        {
            return SolicitudPrestamoService.ObtenerTodasLasSolicitudesPrestamo();
        }

        // GET api/<controller>/5
        public string Get(int id)
        {
            return "value";
        }

        // POST api/<controller>
        public void Post([FromBody]string value)
        {
        }

        // PUT api/<controller>/5
        public void Put(int id, [FromBody]string value)
        {
        }

        // DELETE api/<controller>/5
        public void Delete(int id)
        {
        }
    }
}